; ModuleID = "/Users/hzy/Documents/Projects/MelodieABM/MelodieFuture/llvm/ast_parser.py"
target triple = "unknown-unknown-unknown"
target datalayout = ""

declare double @"pow"(double %".1", double %".2") 

define double @"nested_while_loop"(double %".1") 
{
entry:
  %"count" = alloca double
  store double              0x0, double* %"count"
  %"count.1" = load double, double* %"count"
  call void @"printer"(double %"count.1")
  %"i" = alloca double
  store double              0x0, double* %"i"
  %"i.1" = load double, double* %"i"
  %"j" = alloca double
  store double              0x0, double* %"j"
  %"j.1" = load double, double* %"j"
  call void @"printer"(double %"j.1")
  br label %"_block_while_loop1"
_block_while_loop1:
  %"i.2" = phi double [%"i.1", %"entry"], [%"i.4", %"_block_after_while_loop5"]
  %"count.2" = phi double [%"count.1", %"entry"], [%"count.5", %"_block_after_while_loop5"]
  %"j.2" = phi double [%"j.1", %"entry"], [%"j.5", %"_block_after_while_loop5"]
  %".7" = sitofp i64 1 to double
  %"_tmp3" = fadd double %"i.2", %".7"
  %"i.3" = alloca double
  store double %"_tmp3", double* %"i.3"
  %"i.4" = load double, double* %"i.3"
  br label %"_block_while_loop4"
_block_after_while_loop2:
  ret double %"count.5"
_block_while_loop4:
  %"count.3" = phi double [%"count.2", %"_block_while_loop1"], [%"count.5", %"_block_while_loop4"]
  %"j.3" = phi double [%"j.2", %"_block_while_loop1"], [%"j.5", %"_block_while_loop4"]
  %".10" = sitofp i64 1 to double
  %"_tmp6" = fadd double %"count.3", %".10"
  %"count.4" = alloca double
  store double %"_tmp6", double* %"count.4"
  %"count.5" = load double, double* %"count.4"
  %".12" = sitofp i64 1 to double
  %"_tmp7" = fadd double %"j.3", %".12"
  %"j.4" = alloca double
  store double %"_tmp7", double* %"j.4"
  %"j.5" = load double, double* %"j.4"
  %"_tmp8" = fcmp olt double %"j.5", %"i.4"
  call void @"printer"(double %"count.5")
  br i1 %"_tmp8", label %"_block_while_loop4", label %"_block_after_while_loop5"
_block_after_while_loop5:
  %"_tmp9" = fcmp olt double %"i.4", %".1"
  br i1 %"_tmp9", label %"_block_while_loop1", label %"_block_after_while_loop2"
}

define void @"printer"(double %".1") 
{
entry:
  %".3" = alloca [6 x i8]
  store [6 x i8] c"World\00", [6 x i8]* %".3"
  %".5" = bitcast [22 x i8]* @"fstr" to i8*
  %".6" = call i32 (i8*, ...) @"printf"(i8* %".5", [6 x i8]* %".3", double %".1")
  ret void
}

@"fstr" = internal constant [22 x i8] c"Hello, %s! %f times!\0a\00"
declare i32 @"printf"(i8* %".1", ...) 

!0 = !DIFile(directory: "bar", filename: "factorial.py")
